package com.financing.wap.dao.impl;

import java.sql.SQLException;
import java.util.List;

import org.springframework.stereotype.Repository;

import com.financing.wap.common.SqlName;
import com.financing.wap.dao.IYouDanAmountDetailDao;
import com.financing.wap.dto.FpYouDanAmountDetailDTO;



@Repository("youDanAmountDetaiDaolImpl")
public class YouDanAmountDetaiDaolImpl extends BaseDaoImpl<FpYouDanAmountDetailDTO, java.lang.Integer> implements IYouDanAmountDetailDao {


	@Override
	public Class<FpYouDanAmountDetailDTO> getEntityClass() {
		return FpYouDanAmountDetailDTO.class;
	}

	@SuppressWarnings("deprecation")
	@Override
	public int insertYouDanAmountDetail(
			FpYouDanAmountDetailDTO youDanAmountDetailDTO) throws SQLException {
		return (Integer)this.sqlMapClientTemplate.insert(SqlName.YouDanAmountDetailSql.addYouDanAmountDetail, youDanAmountDetailDTO);
	}

	@SuppressWarnings({ "deprecation", "unchecked" })
	@Override
	public List<FpYouDanAmountDetailDTO> queryYouDanAmountDetailList(
			FpYouDanAmountDetailDTO youDanAmountDetailDTO) throws SQLException {
		return this.sqlMapClientTemplate.queryForList(SqlName.YouDanAmountDetailSql.queryYouDanAmountDetailList, youDanAmountDetailDTO)	;
	}

	@SuppressWarnings("deprecation")
	@Override
	public void updateYouDanAmountDetail(
			FpYouDanAmountDetailDTO youDanAmountDetailDTO) throws SQLException {
		this.sqlMapClientTemplate.update(SqlName.YouDanAmountDetailSql.updateYouDanAmountDetail, youDanAmountDetailDTO);
		
	}

}
